import { createRouter, createWebHashHistory } from 'vue-router'
import { AppEditView, AppIndexView } from '@/views';
const routes = [
  {
    path: '/AppIndexView/editview',
    component: AppEditView
  },
  {
    path: '/AppIndexView',
    component: AppIndexView
  },
  {
    path: '/',
    redirect: 'AppIndexView'
  },
]

const router = createRouter({
  history: createWebHashHistory(),
  routes,
})

/**
 * 全局路由守卫
 */
router.beforeEach((to, from, next) => {
  console.log(to, from, 111);
  next();
})

export default router;